<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE >
<html>
<head>
    <%--   <%@ include file="/page/common/head.jsp" %> --%>
    <title>Insert title here</title>
    <script type="text/javascript" src="static/js/jquery-1.7.2.js"></script>
    <script type="text/javascript"
            src="static/bootstrap-3.4.1/js/bootstrap.js"></script>
    <link href="static/bootstrap-3.4.1/css/bootstrap.css" rel="stylesheet">

</head>
<body>

<!-- 员工添加的模态框 -->
<div class="modal-fade" id="myModal"  tabindex="-1" role="dialog"
     aria-labelledby="myModalLabel" >
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <h4 class="modal-title" id="myModalLabel">修改信息</h4>
            </div>
            <div class="modal-body">
                <!-- 添加一个form -->
                <form class="form-horizontal" action="UpdateEmpServlet" method="post">
                    <div class="form-group">
                        <label for="inputEmail3" class="col-sm-2 control-label">员工姓名</label>
                        <div class="col-sm-10">
                            <input type="text" name="name" class="form-control"
                                   id="emp_name" value="${Emp.name }">
                            <input type="text" style="display: none" name="id" value="${Emp.id }">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="inputPassword3" class="col-sm-2 control-label">员工部门</label>
                        <div class="col-sm-10">
                            <input type="text" name="depart" class="form-control"
                                   id="emp_deaprt" placeholder="depart" value="${Emp.depart }">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="inputPassword4" class="col-sm-2 control-label">员工工资</label>
                        <div class="col-sm-10">
                            <input type="text" name="salary" name="salary" value="${Emp.salary }"
                                   class="form-control" id="emp_salary" placeholder="salary">
                        </div>
                    </div>

                    <button type="submit" class="btn btn-default">确认修改</button>
                </form>
                <button type="button" class="btn btn-default" onclick="closewin()">关闭</button>
            </div>
        </div>
    </div>
</div>

</body>
</html>

<script>
    function closewin() {
        window.location.href = "FindAllServlet";
    }

</script>
